cmake_minimum_required(VERSION 3.20)

project(v2)

# 输出日志(输出 /home/project/cmake/V1/build)
message(${PROJECT_SOURCE_DIR})
message(${CMAKE_CURRENT_SOURCE_DIR})

# 查找头文件
include_directories(${PROJECT_SOURCE_DIR}/include)
# 查找源文件
aux_source_directory(${CMAKE_CURRENT_SOURCE_DIR}/src SRC)

# 输出目录
set (EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/bin)

add_executable(v2 ${SRC})